package com.sxj.corejava.code01_Java基础;

/**
 * @author 石小俊
 * 2024年07月08日 14:09
 */
public class Test04_自动类型转换 {
    public static void main(String[] args) {
        byte b1 = 1;
        short s1 = 1;
        System.out.println(b1 + s1);
        int sum = b1 + s1;

        int i1 = 1;
        int sum2 = b1 + i1;
        long l1 = 1L;
        long sum3 = b1 + l1;

        float f1 = 3.14f;
        double sum4 = b1 + f1;
        double d1 = 5.12;
        double sum5 = b1 + d1;

        char c1 = 'U';
        int sum6 = b1 + c1;
        System.out.println(sum6);


    }
}
